package com.xin.utils;

import org.springframework.mail.javamail.JavaMailSender;

/**
 * email Html 模板 工具类
 */
public class HtmUtils {


    /**
     * 获得多次审核不通过的email模板
     * @param
     * @param content
     * @return
     */
    public static final String getToManAuditsEmailTemplate(String content){

        String html = "<!DOCTYPE html>\n" +
                "<html>\n" +
                "\t<head>\n" +
                "\t\t<meta charset=\"utf-8\">\n" +
                "\t\t<title></title>\n" +
                "\t</head>\n" +
                "\t<body>\n" +
                "\t\t<div class=\"container\">\n" +
                "\t\t\t<h2>"+content+"</h2>\n" +
                "\t\t\t<a href=\"http://127.0.0.1:8080/#/settleIn\">您可以 前往 此处 重新提交材料</a>\n" +
                "\t\t</div>\n" +
                "\t</body>\n" +
                "</html>\n";
        return html;
    }
    /**
     * 获取审核不通过的模板
     * @return
     */
    public static final String getNoPass(String content,String token){
        String html="<!DOCTYPE html>\n" +
                "<html>\n" +
                "\t<head>\n" +
                "\t\t<meta charset=\"utf-8\">\n" +
                "\t\t<title></title>\n" +
                "\t</head>\n" +
                "\t<body>\n" +
                "\t\t<div class=\"container\">\n" +
                "\t\t\t<h2>尊敬的用户您好，您的店铺审核未通过。具体原因如下:\n" +
                ""+content+"\t"+
                "\t\t\t<a href=\"http://127.0.0.1:8080/#/settleIn?token="+token+"\">您可以前往此处重新提交材料</a></h2>\n" +
                "\t\t\n" +
                "\t\t</div>\n" +
                "\t</body>\n" +
                "</html>\n";

        return html;
    }


    /**
     * 获取审核不通过的模板
     * @return
     */
    public static final String getNoPass(String content){
        String html="<!DOCTYPE html>\n" +
                "<html>\n" +
                "\t<head>\n" +
                "\t\t<meta charset=\"utf-8\">\n" +
                "\t\t<title></title>\n" +
                "\t</head>\n" +
                "\t<body>\n" +
                "\t\t<div class=\"container\">\n" +
                "\t\t\t<h2>尊敬的用户您好，您的店铺审核未通过。具体原因如下:\n" +
                ""+content+"\t"+
                "\t\t\t<a href=\"http://127.0.0.1:8080/#/settleIn\">您可以前往此处重新提交材料</a></h2>\n" +
                "\t\t\n" +
                "\t\t</div>\n" +
                "\t</body>\n" +
                "</html>\n";

        return html;
    }

    /**
     *  当用户激活成功的时候，获取该邮件模板
     * @param username
     * @param password
     * @return
     */
    public static String getActiveSuccessTemplate(String username, String password){
        String html="<!DOCTYPE html>\n" +
                "<html>\n" +
                "\t<head>\n" +
                "\t\t<meta charset=\"utf-8\">\n" +
                "\t\t<title></title>\n" +
                "\t</head>\n" +
                "\t<body>\n" +
                "\t\t<div class=\"container\">\n" +
                "\t\t\t<h2>尊敬的用户您好，您的店铺审核已经通过。\n" +
                "\t\t\t <p>这是您的账号和密码:</p>\n" +
                "\t\t\t  <div>账号: "+username+" </div>\n" +
                "\t\t\t  <div>密码: "+password+" </div>\n" +
                "\t\t\t<a href=\"http://127.0.0.1:8080/#/login\">您可以点击此处进行登录</a></h2>\n" +
                "\t\t</div>\n" +
                "\t</body>\n" +
                "</html>\n";

        return  html;
    }




}
